<!DOCTYPE html>
<html>
<head>
    <title>签收详情</title>
    <meta charset=utf-8>
    <meta name=viewport content="width=device-width, initial-scale=1">
    <link rel="stylesheet" type="text/css" href="../../../../start/layui/css/layui.css">
    <script type="text/javascript" src="../../../../start/layui/js/erweima/qrcode.js"></script>
    <style type="text/css">
        td{
            text-align: center;
        }
    </style>
</head>
<body>
<form class="layui-form layui-form-pane" action="">
    <table id="as" style="width:100%;height:580px;" border="1px" >
        <tr>
            <td style="width:80px">托运单号：</td>
            <td colspan="2">
                <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="checkenumber" id="checkenumber" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
            </td>
            <td style="width:80px">运单状态：</td>
            <td>
                <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="yundanstate" id="yundanstate" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
            </td>
            <td style="width:80px">托运日期：</td>
            <td colspan="4">
                <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="checkedate" id="checkedate" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
            </td>
            <td style="width:80px">出发地：</td>
            <td>
                <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="departure" id="departure" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
            </td>
            <td style="width:80px">到达分站：</td>
            <td>
                <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="arrivesubstations" id="arrivesubstations" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
            </td>
            <td style="width:80px">到达城市：</td>
            <td>
                <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="arrivecity" id="arrivecity" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
            </td>
        </tr>
        <tr>
            <td colspan="16" style="height:60px">
                <dd style="text-align-last: center;font-size:16px;">基本信息</dd>
            </td>
        </tr>
        <tr>
            <td>发货单位：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="shippingunits" id="shippingunits" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                <td>发货人：</td>
            <td>
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none;" type="text" name="consigners" id="consigners" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                     <td colspan="2">联系电话：</td>
            <td colspan="3">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="shippingphone" id="shippingphone" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                     <td style="width: 80px">备用电话：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="shippersbackupphone" id="shippersbackupphone" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                     <td>发货地址：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="shippingaddress" id="shippingaddress" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
        </tr>
        <tr>
            <td>收货单位：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="receivingunit" id="receivingunit" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                <td>收货人：</td>
            <td>
                    <input  style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="consignees" id="consignees" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                     <td colspan="2">联系电话：</td>
            <td colspan="3">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="receivingphone" id="receivingphone" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                     <td>备用电话：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="consigneesbackupphone" id="consigneesbackupphone" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                     <td>收货地址：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="receiptaddress" id="receiptaddress" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
        </tr>
        <tr>
            <td colspan="16" style="height:60px">
                <dd style="text-align-last: center;font-size:16px;">托运信息</dd>
            </td>
        </tr>
        <tr>
            <td>送货方式：</td>
            <td>
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="deliverymethod" id="deliverymethod" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
            <td style="width: 90px">运输类型：</td>
            <td>
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="transporttype" id="transporttype" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
            <td>承诺日期：</td>
            <td colspan="3">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="promisedate" id="promisedate" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                <td colspan="2" style="width: 70px">订单编号：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="ordersnumber" id="ordersnumber" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                <td>跟踪短信：</td>
            <td>
                    <input type="radio" name="message" value="跟踪短信">
                </td>
                <td>签收短信：</td>
            <td>

                  <input type="radio" name="message" value="签收短信">


            </td>
            </tr>

            <tr>
                    <td colspan="2" style="height:30px;">货物名称</td>
                    <td colspan="3">数量</td>
                    <td colspan="2">包装</td>
                    <td colspan="2">重量/kg</td>
                    <td colspan="3">体积/m3</td>
                    <td colspan="3">单价</td>
                    <td colspan="2">到付</td>
            </tr>
            <tr>
                    <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="goodsname" id="goodsname" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                    <td colspan="3">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="goodsquantity" id="goodsquantity" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                    <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="wrapmanner" id="wrapmanner" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                    <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="goodsweight" id="goodsweight" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                    <td colspan="3">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="goodsvolume" id="goodsvolume" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                </td>
                <td colspan="3">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="goodsunitprice" id="goodsunitprice" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                    <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="paydelivery" id="paydelivery" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
            </tr>
            <tr>
                <td rowspan="2">运单跟踪:</td>
                <td rowspan="2" colspan="4" style="border-bottom-style:none">
                        <textarea name="vehicleremark" id="vehicleremark" placeholder="" class="layui-textarea"></textarea>
                </td>
                <td rowspan="2" colspan="2">
                    运单码:
                </td>
                <td rowspan="2">
                    <div class="codeImg" id="event_qrcode"></div>
                </td>
                <td rowspan="2" colspan="2">
                    跟踪码:
                </td>
                <td rowspan="2">
                    <div class="codeImg" id="trackingcode"></div>
                </td>
                <td rowspan="2" colspan="2">
                    PDF运单下载
                </td>
            <td colspan="1" style="border-bottom-style:none">

            </td>
            <td>开单员:</td>
            <td>
                <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="operateyuan" id="operateyuan" placeholder="" autocomplete="off" class="layui-input">
                </td>
            </tr>
            <tr>
            <td style="border-top-style:none"></td>
                <td colspan="2">
                    <a id="printTable" class="layui-btn">打印签收单</a>
                </td>
            </tr>
             <tr>
            <td colspan="16" style="height:60px">
                <dd style="text-align-last: center;font-size:16px;">其它信息</dd>
            </td>
        </tr>
            <tr>
            <td>发车日期：</td>
            <td>
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="departuretime" id="departuretime" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                <td>运输状态：</td>
            <td>
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="transportstatus" id="transportstatus" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                     <td>运输车号：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="transportcarnumber" id="transportcarnumber" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
             </td>
                     <td>运输司机：</td>
            <td>
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="drivername" id="drivername" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
            </td>
                     <td colspan="2">司机电话：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="driverphone" id="driverphone" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                <td colspan="2">外包运费：</td>
            <td >
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="outsourcedfreight" id="outsourcedfreight" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
        </tr>
                    <tr>
            <td>入库站点：</td>
            <td>
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="storagesite" id="storagesite" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                <td>派送时间：</td>
            <td>
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="deliverytime" id="deliverytime" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                     <td>外包公司：</td>
            <td colspan="3">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="outsourcingcompany" id="outsourcingcompany" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
               </td>
                     <td>外包电话：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="outsourcephone" id="outsourcephone" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                     <td>转包日期：</td>
            <td colspan="2">
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="subcontractingdate" id="subcontractingdate" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
                <td >外包类型：</td>
            <td >
                    <input style="border-top-style:none;border-bottom-style:none;border-right-style:none" type="text" name="outsourcingtype" id="outsourcingtype" lay-verify="required" placeholder="" autocomplete="off" class="layui-input">
                </td>
        </tr>
    </table>
</form>
</body>
<script>
    layui.use(['form', 'layedit', 'laydate','table'], function(){
        var form = layui.form
            ,layer = layui.layer
            ,layedit = layui.layedit
            ,laydate = layui.laydate
            ,table = layui.table;
            var $ = layui.jquery;

        $("#printTable").click(function () {
                window.print();
        })
        /*跟踪文本域拉框赋值*/
        $.ajax({
            url:"../../../../getTailafterlist",
            success:function(data){
                for(var i =0;i<data.length;i++){
                    var parent=document.getElementById("vehicleremark");
                    var child=document.createTextNode("运单码:"+data[i].waybillId+"\t操作时间:"+data[i].tailafterTime+"\t操作内容:"+data[i].state);
                    parent.appendChild(child);
                    
                }
            }
        });

        /*设置运单码*/
        var qrcode = new QRCode(document.getElementById("event_qrcode"), {
            width : 104.4,  //二维码图片的长度
            height : 104.4  //宽度

        });

        /*设置跟踪码*/
        var track = new QRCode(document.getElementById("trackingcode"), {
            width : 104.4,  //二维码图片的长度
            height : 104.4  //宽度

        });

        /*设置二维码内容*/
        function trackingcode () {
            var elText = "跟踪码";  //你要生成二维码的内容
            track.makeCode(elText);
        }
        //启用
        trackingcode();

        /*设置二维码内容*/
        function makeCode () {
            var elText = "运单码";  //你要生成二维码的内容
            qrcode.makeCode(elText);
        }
        //启用
        makeCode();
    });
</script>
</html>